<!doctype html>
<html>
<head>
<meta charset="utf-8" />
<meta content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no" name="viewport" />
<title>网络中国节详情页</title>
<meta content="" name="keywords" />
<meta content="" name="description" />
<meta content="" name="author" />
<link href="__css__style.css" type="text/css" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="__font__iconfont.css">
<script type="text/javascript" src="__js__jquery-1.9.1.min.js"></script>
</head>

<body>
    <p class="tishi">您已投票成功</p>
	<div class="w">
        <if condition="$atcdetail.urladdr neq ''">
		    <div class="video-box">
                <a href="{$atcdetail.urladdr}">
                    <img src="{$atcdetail.picture}" width="100%">
                </a>
            </div>
            <div class="content-box">
                <h4>{$atcdetail.title}</h4>
                <div class="tag-bg">
                    <img src="__img__tag.png">
                    <em>{$atcdetail.authornm}</em>
                </div>
                <p>{$atcdetail.content}</p>
            </div>
        <else/>
            <div class="video-box">
              <if condition="$atcdetail.netid eq '7' ">
                <video width="100%" controls class="video-style">
                        <source src="{$movie}" type="video/mp4">
                        <source src="{$movie}" type="video/ogg">
                </video>
              <elseif condition="$atcdetail.netid eq '5' "/> 
                <video width="100%" controls class="video-style">
                        <source src="{$movie}" type="video/mp4">
                        <source src="{$movie}" type="video/ogg">
                </video>
              <elseif condition="$atcdetail.netid eq '2' "/> 
                <video width="100%" controls class="video-style">
                        <source src="{$movie}" type="video/mp4">
                        <source src="{$movie}" type="video/ogg">
                </video>
              <else/>
                <img src="{$atcdetail.picture}" width="370px" height="245px">
              </if>
            </div>
            <div class="content-box">
                 {$atcdetail.summary}
            </div>
       </if>
	</div>
	<!--footer-->
    <div class="footer2 clearfix">
        <div class="divd-a fl clearfix">
            <a href="{:U('index')}"><i class="shortmovie  shortmovie-shouye1 footer2-icon"></i></a>
            <a><i class="shortmovie footer2-icon2 shortmovie-xingguang"></i><br/><div class="num b clearfix" id="num"><span>{$atcdetail.votes}</span><b>票</b></div></a>
            <a class="border-clear"><i class="shortmovie footer2-icon2 shortmovie-paixingbang"></i><br/><div class="b clearfix"><span>{$pm}</span><b>名</b></div></a>
        </div>
        <div class="divd-b clearfix fl"><a class="in-vote-btn" actid="{$atcdetail.id}" num="{$atcdetail.votes}">给TA投票</a></div>
    </div>
<!--foot over-->
<!--ready_box over-->
<script type="text/javascript">
    $(document).ready(function($) {
        $(".divd-b").click(function(event) {
            $(".tishi").fadeIn();
        });
        var timesRun = 0;
        var interval = setInterval(function(){
        timesRun += 1;
        if(timesRun === 60){
        clearInterval(interval);
        }
        $(".tishi").fadeOut()
        }, 2000);
    });

     

        $(".in-vote-btn").click(function(){ 
            var articid =  $(this).attr("actid");
            var numval  =  $("#num").html();
           // var numval  =  $(this).attr("num");
             $.ajax({ 
                type: 'POST', 
                url: '__URL__/addVote', 
                dataType:'JSON',
                data: {articid:articid,num:numval,rand:Math.random()}, 
                success: function (data) { 
                 //  alert(JSON.stringify(data.votes));
                 if(data==1){ 
                    $(".tishi").html("不能投票超过3次,明天再来吧");
                 }else if (data==5){ 
                    $(".tishi").show();
                    $(".tishi").html("我们的投票结束啦,谢谢大家");
                }else{ 
                    $(".tishi").html("您已经投票成功");
                 }
                // $("b.num").html(data.votes);
                 $("#num").html(data.votes);

                } 
             });
        });

</script>
<script>
var _hmt = _hmt || [];
(function() {
  var hm = document.createElement("script");
  hm.src = "https://hm.baidu.com/hm.js?996ff5636cc816a4703cb2156ef1796b";
  var s = document.getElementsByTagName("script")[0]; 
  s.parentNode.insertBefore(hm, s);
})();
</script>
</body>
</html>
